/*
 * Copyright 2017 hv0912
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *  http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.vimhe.ezimp2.handler;

import com.vimhe.ezimp2.config.bean.ColumnConfig;
import com.vimhe.ezimp2.config.bean.FileConfig;
import com.vimhe.ezimp2.config.bean.RowConfig;
import com.vimhe.ezimp2.config.bean.SheetConfig;
import com.vimhe.ezimp2.handler.bean.CellData;
import com.vimhe.ezimp2.handler.bean.FileData;
import com.vimhe.ezimp2.handler.bean.RowData;
import com.vimhe.ezimp2.handler.bean.SheetData;

/**
 * 数据读取器接口
 *
 * @author Vimhe
 */
public interface Reader {

    /**
     * 读取一个单元格的数据
     *
     * @param cellData     单元格数据对象
     * @param columnConfig 单元格配置对象
     */
    void read(CellData cellData, ColumnConfig columnConfig);

    /**
     * 读取一行的数据
     *
     * @param rowData   行数据对象
     * @param rowConfig 行配置对象
     */
    void read(RowData rowData, RowConfig rowConfig);

    /**
     * 读取一个工作表的数据
     *
     * @param sheetData   工作表数据对象
     * @param sheetConfig 工作表配置对象
     */
    void read(SheetData sheetData, SheetConfig sheetConfig);

    /**
     * 读取一个文件的数据
     *
     * @param fileData   文件数据对象
     * @param fileConfig 文件配置对象
     */
    void read(FileData fileData, FileConfig fileConfig);

}
